package com.mop.sg2.layer;

import android.content.Context;
import android.view.ViewGroup;
import android.widget.RelativeLayout;

import com.mop.sg2.R;
import com.mop.sg2.map.BackGroupView;
import com.mop.sg2.map.BaseAnimView;
import com.mop.sg2.map.CityPanel;
import com.mop.sg2.util.AnimFactory;

public class CityScene extends RelativeLayout{

	public BackGroupView backGroupView = null;
	public BaseAnimView levelUpView=null;
	public CityPanel cityPanel=null;
	public CityScene(Context context){
		super(context);
		backGroupView=new BackGroupView(context);		
		cityPanel=new CityPanel(context);
		this.addView(backGroupView);		
		
		RelativeLayout.LayoutParams lp = new RelativeLayout.LayoutParams(ViewGroup.LayoutParams.WRAP_CONTENT, ViewGroup.LayoutParams.WRAP_CONTENT);
		lp.addRule(RelativeLayout.CENTER_HORIZONTAL,backGroupView.getId());
		lp.addRule(RelativeLayout.CENTER_VERTICAL,backGroupView.getId());
		this.addView(cityPanel,lp);

		levelUpView=AnimFactory.create(context, this, R.anim.levelup_animation, -60, -80);
	}
}
